package com.ffcs.ssh.dao.base;

import java.util.List;

import org.springframework.stereotype.Repository;

import com.ffcs.ssh.common.hibernate.HibernateDao;
import com.ffcs.ssh.entity.base.User;

@Repository
public class UserDao extends HibernateDao<User>{

	/**
	 * 根据登录名与密码查找对应用户，用于登录验证
	 */
	public List<User> getUser(final String username,final String password){
		return super.createQuery("from User a where a.username = ? and a.password = ?",username,password).list();
	}
}